package com.leetao.ifkiller.domain;

import java.util.function.Predicate;

/**
 * Predicate增强版
 *
 * @author 菅江晖
 * @date 2021/6/11 - 0:38
 */
public class PredicatePro<T> {
    String description;
    Predicate<T> predicate;

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public PredicatePro<T> description(String description) {
        this.description = description;
        return this;
    }

    public Predicate<T> getPredicate() {
        return predicate;
    }

    public void setPredicate(Predicate<T> predicate) {
        this.predicate = predicate;
    }

    public PredicatePro<T> predicate(Predicate<T> predicate) {
        this.predicate = predicate;
        return this;
    }

    public static <T> PredicatePro<T> create(T t) {
        return new PredicatePro<>();
    }

}
